package gamecomponents.levelcomponents.stagelements.buildingmats;
import gamecomponents.character.Player;
import gamecomponents.levelcomponents.stagelements.blockhelper.Interval;
import gamecomponents.navigation.Direction;
import gamecomponents.navigation.Location;
import gamecomponents.skeletontesthelper.Assistant;
import gamecomponents.skeletontesthelper.Interaction;
import gamecomponents.skeletontesthelper.Parameter;

/**
 * @author Akos
 * @version 1.0
 * @created 14-márc.-2012 16:36:11
 */
public class Wall extends ExtendedEntity {

	private int peak1;
	private int peak2;

	public Wall(){
            Parameter param[]=new Parameter[1];
            param[0]=new Parameter(null);
            Assistant.write(Interaction.RET,this,"Wall",param);
	}

	public void finalize() throws Throwable {
		super.finalize();
	}

	/**
	 * 
	 * @param peak1
	 * @param peak2
	 * @param peak3
	 */
	public Wall(Location peak1, Location peak2, Location peak3){
            Parameter param[]=new Parameter[3];
            param[0]=new Parameter(peak1);
            param[1]=new Parameter(peak2);
            param[2]=new Parameter(peak3);
            Assistant.write(Interaction.RET,this,"Wall",param);
	}

	public boolean canIGo(){
            Parameter param[]=new Parameter[1];
            param[0]=new Parameter(null);
            Assistant.write(Interaction.CALL,this,"canIGo",param);
            Parameter parameter[]=new Parameter[1];
            parameter[0]=new Parameter("placeholder", false);
            Assistant.write(Interaction.RET,this,"canIGo",parameter);
		return false;       //mehet-e ide a figura, falba értelemszerüen nem
	}

	/**
	 * 
	 * @param dir
	 */
	public Interval getInterval(Direction dir){
            Parameter param[]=new Parameter[1];
            param[0]=new Parameter(dir);
            Assistant.write(Interaction.CALL,this,"getInterval",param);
            Parameter parameter[]=new Parameter[1];
            parameter[0]=new Parameter("Interval");
            Assistant.write(Interaction.RET,this,"getInterval",parameter);
		return null;        //visszaadja az adott szélhez tartozó részét intervallumként
	}

	/**
	 * 
	 * @param loc
	 */
	public boolean isInside(Location loc){
            Parameter param[]=new Parameter[1];
            param[0]=new Parameter(loc);
            Assistant.write(Interaction.CALL,this,"isInside",param);
            Parameter parameter[]=new Parameter[1];
            parameter[0]=new Parameter("boolean");
            Assistant.write(Interaction.RET,this,"isInside",parameter);
		return false;     //megmondja hogy az adott pont benne van-e a falban
	}

	/**
	 * 
	 * @param pl
	 */
	public void action(Player pl){
            Parameter param[]=new Parameter[1];
            param[0]=new Parameter(pl);
            Assistant.write(Interaction.CALL,this,"action",param);
            Parameter parameter[]=new Parameter[1];
            parameter[0]=new Parameter(null);
            Assistant.write(Interaction.RET,this,"action",parameter);
	}

}